package com.hehe.controller;


import com.hehe.Dao.Test_Mapper;
import com.hehe.Dao.Update_mapper;
import org.json.JSONException;
import org.json.JSONObject;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

@Controller
@RequestMapping(value="/count")
public class Count {

    @Autowired
    private Test_Mapper test_mapper;

    @PostMapping(value = "/all")
    @ResponseBody
    public Integer level_300(Model model, @RequestBody String json_data) throws JSONException {
        Integer integer = test_mapper.get_count_All();
        return integer;
    }


}




